Get orders
GET/bot-gateway-service/api/v3/allOrders
Fetches order information based on the provided filters.
- Get all account orders – active, canceled, or filled.
- If
orderId
is set, it will get orders >= thatorderId
. Otherwise, most recent orders are returned. - If
startTime
and/orendTime
are provided, thenorderId
is not required.
Request
Query Parameters
- If orderId is set, it will get orders >= that orderId. Otherwise most recent orders are returned.
- UTC timestamp in ms.
- UTC timestamp in ms.
- Default 500; max 1000.
- RecvWindow is optional.
- The value cannot be greater than 60000.
- If recvWindow is not sent, it defaults to 5000.
Symbol of the trading pair (e.g., XCBETH) (optional).
The unique identifier of the order
of type big integer generated by the Ping Exchange (optional).
The creation time of the orders should be greater than or equal StartTime (optional).
The creation time of the orders should be less than or equal EndTime (optional).
Maximum number of orders requested (optional).
The number of milliseconds after timestamp the request is valid for (optional).
Responses
- 200
- 401
Success
- application/json
- Schema
- Example (from schema)
- Example
Schema
Array [
- Unless
OCO
, value will be -1 - It is the client’s original ClientOrderId of the order from the request.
- executedQty is how many base asset is matched in the order, which is 0.5 in the above example.
- It is how much the user paid for buying base asset in quote asset.
Possible values
:- NEW
- PARTIALLY_FILLED
- FILLED
- CANCELED
- REJECTED
- EXPIRED
- Possible values:
- Good till Canceled (GTC)
- Immediate or Cancel (IOC)
- Fill-Or-Kill (FOK)
- Possible values:
- LIMIT
- MARKET
- STOP_LOSS_LIMIT
- TAKE_PROFIT_LIMIT
- STOP_LOSS_LIMIT
- LIMIT_MAKER
- STOP_LOSS
- TAKE_PROFIT
- Used with STOP_LOSS, STOP_LOSS_LIMIT, TAKE_PROFIT, and TAKE_PROFIT_LIMIT orders.
- Used with LIMIT, STOP_LOSS_LIMIT, and TAKE_PROFIT_LIMIT to create an iceberg order.
- It’s the same “w” field returned from websocket executionReport event.
- Possible values: NONE, EXPIRE_TAKER, EXPIRE_MAKER, EXPIRE_BOTH
]
Symbol of the trading pair (e.g., XCBETH).
The unique identifier of the order
of type big integer generated by the Ping Exchange.
The unique identifier of the order list generated by the Ping Exchange.
The unique identifier (Guid) assigned by the client for the order.
The price is the client’s original price of the order from the request.
The original quantity requested by the client.
The quantity of the base asset that has been executed in the order (e.g., 0.5).
The total cost of buying the base asset in the quote asset.
The status of the order.
Order time in force.
Order type , e.g. LIMIT.
Order side: e.g. BUY or SELL.
The stop order activation price.
The quantity of the iceberg order.
The timestamp of the transaction.
The timestamp of the last update.
Indicates if the order is currently placed in the order book or not.
The time when the order was last marked as working.
The original quote order quantity.
The mode for self-trade prevention.
[
{
"symbol": "XCBETH",
"orderId": 5343,
"orderListId": 12,
"clientOrderId": "09D6C415-996F-4FBA-8C52-22F08D7AF53E",
"price": "0.002",
"origQty": "0.01",
"executedQty": "0.05",
"cummulativeQuoteQty": "0.5",
"status": "NEW",
"timeInForce": "GTC",
"type": "LIMIT",
"side": "BUY",
"stopPrice": "0.1",
"icebergQty": "0.1",
"transactTime": 1643678921,
"updateTime": 1643678921,
"isWorking": true,
"workingTime": 1643678921,
"origQuoteOrderQty": "0.01",
"selfTradePreventionMode": "EXPIRE_TAKER"
}
]
[
{
"symbol": "BTCUSDC",
"orderId": 28,
"orderListId": -1,
"clientOrderId": "9039c673-b545-4b76-b09a-e9bbd80d4030",
"price": "1000",
"origQty": "0.05",
"executedQty": "0.01",
"cummulativeQuoteQty": "0.01",
"status": "PARTIALLY_FILLED",
"timeInForce": "GTC",
"type": "LIMIT",
"side": "SELL",
"stopPrice": "0.0",
"icebergQty": "0.0",
"transactTime": 1715673764827,
"updateTime": 1715673784827,
"isWorking": true,
"workingTime": 1715673734827,
"origQuoteOrderQty": "0.000000",
"selfTradePreventionMode": "EXPIRE_TAKER"
},
{
"symbol": "XCBETH",
"orderId": 100,
"orderListId": -1,
"clientOrderId": "fc08d233-f7c9-4e12-af6a-d82b14374e42",
"price": "0",
"origQty": "0.5",
"executedQty": "0.5",
"cummulativeQuoteQty": "50000",
"status": "FILLED",
"timeInForce": "GTC",
"type": "MARKET",
"side": "BUY",
"stopPrice": "0.0",
"icebergQty": "0.0",
"transactTime": 1715673764827,
"updateTime": 1715673784827,
"isWorking": false,
"workingTime": 1715673734827,
"origQuoteOrderQty": "0.000000",
"selfTradePreventionMode": "EXPIRE_TAKER"
}
]
Unauthorized